<%@ page contentType="text/html;charset=UTF-8" %>
<%@ include file="/common/taglibs.jsp" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
	<title>Web 资源管理</title>
	<%@ include file="/common/meta.jsp" %>
	<link href="${ctx}/css/style.css" type="text/css" rel="stylesheet"/>
	<link href="${ctx}/js/validate/jquery.validate.css" type="text/css" rel="stylesheet"/>
	<script src="${ctx}/js/jquery.js" type="text/javascript"></script>
	<script src="${ctx}/js/validate/jquery.validate.js" type="text/javascript"></script>
	<script src="${ctx}/js/validate/messages_cn.js" type="text/javascript"></script>

	<script>
		$(document).ready(function() {
			//聚焦第一个输入框
			$("#name").focus();
			//为inputForm注册validate函数
			$("#inputForm").validate();
		});
	</script>
</head>

<body style="margin-top:40px;">

<div id="content">
	<h1><img src="${ctx}/skin/images/frame/icon22.gif" align="absbottom"/>&nbsp;&nbsp;<s:if test="id == null">创建</s:if><s:else>修改</s:else>资源</h1>
	<form action="resource!save.action" method="post">
		<input type="hidden" name="page.pageNo" id="pageNo" value="${page.pageNo}"/>
		<input type="hidden" name="page.orderBy" id="orderBy" value="${page.orderBy}"/>
		<input type="hidden" name="page.order" id="order" value="${page.order}"/>
		<input type="hidden" name="filter_LIKES_value"
							 value="${param['filter_LIKES_value']}" size="9"/> 
							 <input type="hidden" name="filter_LIKES_showname"
							 value="${param['filter_LIKES_showname']}" size="9"/>
							<input type="hidden" name="filter_LIKES_urlvalue"
							 value="${param['filter_LIKES_urlvalue']}" size="9"/>
		<input type="hidden" name="id" value="${id}"/>
		<table width="99%" border="0" cellpadding="5" cellspacing="1" bgcolor="#e0e0e0" class="noborder">
			<tr>
				<td width="8%" bgcolor="#F5F5F5">总排序:</td>
			  <td width="92%" bgcolor="#FFFFFF"><input type="text" id="position" name="position" size="40" value="${position}" /></td>
			</tr>
			<tr>
				<td bgcolor="#F5F5F5">父序号:</td>
			  <td bgcolor="#FFFFFF"><input type="text" id="upmenu" name="upmenu" size="40" value="${upmenu}" /></td>
			</tr>
			<tr>
				<td bgcolor="#F5F5F5">名称:</td>
			  <td bgcolor="#FFFFFF"><input type="text" id="showname" name="showname" size="40" value="${showname}" /></td>
			</tr>
			<tr>
				<td bgcolor="#F5F5F5">url类型:</td>
			  <td bgcolor="#FFFFFF"><input type="text" id="resourceType" name="resourceType" size="40" value="${resourceType}" /></td>
			</tr>
			<tr>
				<td bgcolor="#F5F5F5">权限:</td>
			  <td bgcolor="#FFFFFF"><input type="text" id="value" name="value" size="60" value="${value}" /></td>
			</tr>
			<tr>
				<td bgcolor="#F5F5F5">类型:</td>
			  <td bgcolor="#FFFFFF"><input type="text" id="type" name="type" size="40" value="${type}" /></td>
			</tr>
			<tr>
				<td bgcolor="#F5F5F5">Url:</td>
			  <td bgcolor="#FFFFFF"><input type="text" id="urlvalue" name="urlvalue" size="60" value="${urlvalue}" /></td>
			</tr>
			<tr>
				<td bgcolor="#F5F5F5">菜单层次:</td>
			  <td bgcolor="#FFFFFF"><input type="text" id="menulevel" name="menulevel" size="40" value="${menulevel}" /></td>
			</tr>
			<tr>
				<td bgcolor="#F5F5F5">菜单排序:</td>
			  <td bgcolor="#FFFFFF"><input type="text" id="menuorder" name="menuorder" size="40" value="${menuorder}" /></td>
			</tr>
			<tr>
				<td bgcolor="#F5F5F5">授权:</td>
				<td bgcolor="#FFFFFF">
					<div style="word-break:break-all;width:100%;  ">
						<s:checkboxlist name="checkedAuthIds" list="allAuthorityList" listKey="id"
										listValue="displayName" theme="simple"/>
					</div>
			  </td>
			</tr>
			<tr>
				<td colspan="2" align="center" bgcolor="#FFFFFF">
					<security:authorize ifAnyGranted="A_MODIFY_ROLE">
						<input class="button" type="submit" value="提交"/>&nbsp;
					</security:authorize>
			  <input class="button" type="button" value="返回" onclick="history.back()"/></td>
			</tr>
	  </table>
	</form>
</div>

</body>
</html>